package com.lengyu.iottransfer.gateway.service;

import com.lengyu.iottransfer.gateway.entity.DeviceTransfer;
import com.baomidou.mybatisplus.extension.service.IService;

/**
 * <p>
 *  服务类
 * </p>
 *
 * @author liuyu
 * @since 2023-11-02
 */
public interface IDeviceTransferService extends IService<DeviceTransfer> {
    DeviceTransfer getDeviceTransferByGatewaySendTopic(String gatewaySendTopic);

    /**
     * 获取向第三方平台发送设备属性的topic信息
     * @param deviceTransfer
     * @return
     */
    String getThirdPlatPostPropertyTopic(DeviceTransfer deviceTransfer);

    /**
     * 获取向本平台发送设备属性的topic信息
     * @param deviceTransfer
     * @return
     */
    String getIotPlatPropertyTopic(DeviceTransfer deviceTransfer);

    String getIotPlatPropertyTopicV1(String deviceType);

    /**
     * 获取iita平台需要的clientId
     * @param deviceTransfer
     * @return
     */
    String getClientIdForIITA(DeviceTransfer deviceTransfer);

    DeviceTransfer getDeviceTransferByCode(String code);
}
